package br.pucrio.inf.csm;

import java.util.List;

/**
 * Interface used for manipulating instances of the database. TODO: trocar nome
 * para Wrapper???
 * 
 * @author agazola
 * 
 */
public interface ICatalogWrapper {

	/**
	 * Probes the database by injecting the values specified into the schemaAttr
	 * attribute of the targetSchema instances. The result is the frequency of
	 * occurrence of "value" in the schemaAttr of schema instances.
	 * 
	 * @param schema
	 * @param schemaAttr
	 * @param value
	 * @return
	 * @throws CatalogAccessException
	 */
	public int getSimilarityCount(ISchema schema, Attribute schemaAttr,
			String value) throws CatalogAccessException;

	/**
	 * Returns the thesaurus of this catalog...
	 * 
	 * @param schema
	 * @return
	 * @throws CatalogAccessException
	 */
	public List<String> getThesaurus(ISchema schema)
			throws CatalogAccessException;

	/**
	 * 
	 * @param term
	 * @param schema
	 * @return
	 */
	public List<Instance> getInstancesByThesaurusTerm(String term,
			ISchema schema);
}